<?xml version='1.0' encoding='UTF-8' ?>
<!--
Copyright (C) 2014 Eduardo Pereira Montenegro <epereiramontenegro@gmail.com>

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>.
-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:p="http://primefaces.org/ui"
      xmlns:f="http://xmlns.jcp.org/jsf/core">

    <link rel="icon" type="image/png" href="/bambole/resources/image/bambole_icon.png"/>

    <f:view locale="#{localizationUtil.selected}">

        <h:outputStylesheet name="#{themeUtil.css}"/> 

        <h:head>

            <meta http-equiv="Content-Type" 
                  content="text/html; charset=UTF-8" />

            <title>

                <ui:insert name="title">

                    Default Title

                </ui:insert>

            </title>

        </h:head>

        <h:body styleClass="body">

            <p:growl id="messages"/> 

            <p:idleMonitor timeout="#{configurationController.sessionTimeout}">
                <p:ajax event="idle" listener="#{userUtil.sessionTimeout}" update="messages"/>
            </p:idleMonitor>

            <ui:insert name="body">

                Default Body

            </ui:insert>

        </h:body>

        <p:confirmDialog global="true"
                         showEffect="fade" 
                         hideEffect="fade">

            <h:form>

                <h:panelGrid columns="3"
                             columnClasses="columnWidth48, columnWidth4, columnWidth48"
                             width="100%"
                             style="margin-left: auto; margin-right: auto; padding-left: 8%">

                    <p:commandButton value="#{bundle.Yes}"
                                     styleClass="ui-confirmdialog-yes"
                                     type="button"
                                     style="width: 100%"/>

                    <p:spacer/>

                    <p:commandButton value="#{bundle.No}"
                                     styleClass="ui-confirmdialog-no"
                                     type="button"
                                     style="width: 100%"/>           

                </h:panelGrid>

            </h:form> 

        </p:confirmDialog> 

        <script type="text/javascript">

            function imageDestroy() {
                var currentImage = $('.current_image');
                currentImage.attr(null);
            }

        </script>

        <script type="text/javascript">
            PrimeFaces.locales['pt_BR'] = {
                closeText: 'Fechar',
                prevText: 'Anterior',
                nextText: 'Próximo',
                currentText: 'Hoje: #{localizationUtil.today}',
                monthNames: ['Janeiro', 'Fevereiro', 'Março', 'Abril', 'Maio', 'Junho', 'Julho', 'Agosto', 'Setembro', 'Outubro', 'Novembro', 'Dezembro'],
                monthNamesShort: ['Jan', 'Fev', 'Mar', 'Abr', 'Mai', 'Jun', 'Jul', 'Ago', 'Set', 'Out', 'Nov', 'Dez'],
                dayNames: ['Domingo', 'Segunda', 'Terça', 'Quarta', 'Quinta', 'Sexta', 'Sábado'],
                dayNamesShort: ['Dom', 'Seg', 'Ter', 'Qua', 'Qui', 'Sex', 'Sáb'],
                dayNamesMin: ['D', 'S', 'T', 'Q', 'Q', 'S', 'S'],
                weekHeader: '',
                firstDay: 0,
                isRTL: false,
                showMonthAfterYear: false,
                yearSuffix: '',
                timeOnlyTitle: 'Só horas',
                timeText: 'Horário',
                hourText: 'Hora',
                minuteText: 'Min.',
                secondText: 'Seg.',
                ampm: false,
                month: 'Mês',
                week: 'Semana',
                day: 'Dia',
                allDayText: 'Dia todo'
            };
        </script>

        <script type="text/javascript">
            PrimeFaces.locales ['en_US'] = {
                closeText: 'Close',
                prevText: 'Previous',
                nextText: 'Next',
                monthNames: ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'],
                monthNamesShort: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],
                dayNames: ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'],
                dayNamesShort: ['Sun', 'Mon', 'Tue', 'Wed', 'Tue', 'Fri', 'Sat'],
                dayNamesMin: ['S', 'M', 'T', 'W ', 'T', 'F ', 'S'],
                weekHeader: '',
                firstDay: 0,
                isRTL: false,
                showMonthAfterYear: false,
                yearSuffix: '',
                timeOnlyTitle: 'Time only',
                timeText: 'Time',
                hourText: 'Hour',
                minuteText: 'Min.',
                secondText: 'Sec.',
                currentText: 'Today: #{localizationUtil.today}',
                ampm: false,
                month: 'Month',
                week: 'Week',
                day: 'Day',
                allDayText: 'All day'
            };
        </script>

    </f:view>

</html>
